#include <iostream>
#include "nrcomplex.h"
int x;
Complex::Complex(double r,double i){
(*this).re=r;
(*this).im=i;
}
VectorComplex::VectorComplex(int n){
for(int i=0,x=n;i<n;i++){
std::cout<<"Introduceti numarul complex\n";
std::cout<<"Partea reala=";
std::cin>>nrcomplexe[i].re;
std::cout<<"Partea imaginara=";
std::cin>>nrcomplexe[i].im;
	}
}
VectorComplex VectorComplex::operator +(VectorComplex v){
VectorComplex sum(x);
for(int i=0;i<x;i++){
sum.nrcomplexe[i].re=v.nrcomplexe[i].re+(*this).nrcomplexe[i].re;
sum.nrcomplexe[i].im=v.nrcomplexe[i].im+(*this).nrcomplexe[i].im;
}

}

